package com.oa.modules.approvalsec1.service.impl;

import com.oa.common.utils.AppUtils;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.oa.common.utils.PageUtils;
import com.oa.common.utils.Query;

import com.oa.modules.approvalsec1.dao.ApprovalTotalDao;
import com.oa.modules.approvalsec1.entity.ApprovalTotalEntity;
import com.oa.modules.approvalsec1.service.ApprovalTotalService;


@Service("approvalTotalService")
public class ApprovalTotalServiceImpl extends ServiceImpl<ApprovalTotalDao, ApprovalTotalEntity> implements ApprovalTotalService {

    @Override
    public PageUtils queryPage(Map<String, Object> params) {
        IPage page= AppUtils.getPage(new Query<ApprovalTotalEntity>(), params);
        return AppUtils.setPage(page, baseMapper.findPage(params), baseMapper.findRecords(page, params));
    }

    @Override
    public void batchSave(List<ApprovalTotalEntity> list) {
        baseMapper.batchSave(list);
    }

    @Override
    public void batchUpdate(List<ApprovalTotalEntity> list) {
        baseMapper.batchUpdate(list);
    }

    @Override
    public ApprovalTotalEntity select(ApprovalTotalEntity approvalTotalEntity) {
        return baseMapper.select(approvalTotalEntity);
    }

    @Override
    public void singleUpdate(ApprovalTotalEntity approvalTotalEntity) {
        baseMapper.singleUpdate(approvalTotalEntity);
    }

    @Override
    public void singleSave(ApprovalTotalEntity approvalTotalEntity) {
        baseMapper.singleSave(approvalTotalEntity);
    }

}